package com.xcm.sso.client.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;

@Controller
public class IndexController {
	@RequestMapping(value = "/index")
	public String testSSO(Model model, HttpServletRequest request) {
		HttpSession session = request.getSession(true);
		model.addAttribute("token", session.getAttribute("token"));
		return  "index";
	}
}
